package com.db.stexchem.message;

public class PlaceOrderResponse extends Data {
  
  private Status status;
  private Integer orderNo;
  private String errorMessage;
  
  public PlaceOrderResponse() {
  }

  public Status getStatus() {
    return status;
  }

  public void setStatus(Status status) {
    this.status = status;
  }

  public Integer getOrderNo() {
    return orderNo;
  }

  public void setOrderNo(Integer orderNo) {
      this.orderNo = orderNo;
  }

  public String getErrorMessage() {
    return errorMessage;
  }

  public void setErrorMessage(String errorMessage) {
    this.errorMessage = errorMessage;
  }

  @Override
  public boolean equals(Object obj) {
    if (this == obj)
      return true;
    if (obj == null)
      return false;
    if (getClass() != obj.getClass())
      return false;
    PlaceOrderResponse other = (PlaceOrderResponse) obj;
    if (errorMessage == null) {
      if (other.errorMessage != null)
        return false;
    } else if (!errorMessage.equals(other.errorMessage))
      return false;
    if (orderNo == null) {
      if (other.orderNo != null)
        return false;
    } else if (!orderNo.equals(other.orderNo))
      return false;
    if (status != other.status)
      return false;
    return true;
  }

  @Override
  public String toString() {
    return "PlaceOrderResponse [status=" + status + ", orderNo=" + orderNo
        + ", errorMessage=" + errorMessage + "]";
  }
  
}
